﻿@model csharp_movies_415.Models.MovieIndexVm
@{
    ViewBag.Title = "Home Page";
}

<div class="jumbotron">
    <h1>@Model.Greeting</h1>
</div>

<div class="row">
    <div class="col-md-8 col-md-offset-2">
        <h2>Movie List</h2>
        <table class="table table-hover">
            <tr>
                <th>ID</th>
                <th>Movie</th>
                <th>Rating</th>
                <th>Release Date</th>
                <th>Poster</th>
            </tr>
            @foreach (var m in Model.MovieList)
            {
                <tr>
                    <th>@m.MovieId</th>
                    <th>@m.MovieName</th>
                    <th>@m.Rating</th>
                    <th>@m.ReleaseYear</th>
                    <th><img class="img-rounded" width="25px" height="50px" src="@m.PosterUrl"/></th>
                </tr>
            }
        </table>
    </div>
</div>